package com.ailot.cloud.base.log;

import com.ailot.cloud.base.log.aspect.SysLogAspect;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.ApplicationEventPublisher;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.annotation.Order;

/**
 * 日志配置
 *
 * @author litao
 */
@Order
@Slf4j
@Configuration
public class LogAutoConfiguration {

    @Bean
    public SysLogAspect sysLogAspect(ApplicationEventPublisher publisher) {
        log.info("日志组件初始化");
        return new SysLogAspect(publisher);
    }
}
